<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
    
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>Insert title here</title>
</head>
<body>
<h1>用户信息:${user.nickname},<a href="logout">登出</a></h1>

<h1>单词列表</h1>
<table border=1>
	<tr><td>序号</td><td>单词</td><td>中文</td><td>修改<td>删除</td></tr>
	<c:forEach items="${words}" var="w">
		<tr><td>${w.id}</td><td>${w.word}</td><td>${w.chinese}</td>
		<td><a href="word_modify?id=${w.id}">修改</a></td>
		<td><a href="word_del?id=${w.id}">删除</a></td>
		</tr>
	</c:forEach>
	
</table>
<h1>添加</h1>
<form action="word_add">
单词<input type=text name="word">
中文<input type=text name="chinese">
<input type="submit" value="添加" >
</form>

<h1>修改</h1>
<form action="word_update">
编号<input type=text name="id">
单词<input type=text name="word">
中文<input type=text name="chinese">
<input type="submit" value="修改" >
</form>
</body>
</html>